package com.vincent.template.repository;

import com.vincent.template.commons.base.BaseJpaRepository;
import com.vincent.template.domain.SysBindAuthGroupRolePo;

import java.util.Collection;
import java.util.List;

/**
 * @author Vincent Wang
 * @date 2020/12/30 11:15
 */
public interface SysBindAuthGroupRoleRepository extends BaseJpaRepository<SysBindAuthGroupRolePo, Long> {
    List<SysBindAuthGroupRolePo> findByRoleIdIn(Collection<Long> roleIds);
    List<SysBindAuthGroupRolePo> findByAuthGroupId(Long authGroupId);
    int deleteByRoleId(Long roleId);
    List<SysBindAuthGroupRolePo> findByAuthGroupIdInAndRoleId(Collection<Long> authGroupIds, Long roleId);
}
